#include <malloc.h>
#include <stdio.h>
int* twoSum(int* numbers, int numbersLen, int target, int* returnSize)
{
    int* ret = (int*)malloc(sizeof(int) * 2);
    int tmp1 = 0;
    int tmp2 = 0;
    for (int i = 0; i < numbersLen; i++)
    {
        for (int j = 0; j < numbersLen; j++)
        {
            if (numbers[i] + numbers[j] == target&&i!=j)
            {
                tmp1 = i;
                tmp2 = j;
                i = 1000;
                break;
            }
        }
    }
    *returnSize = 2;
    ret[0] = tmp1;
    ret[1] = tmp2;
    if (ret[0] < ret[1])
    {
        int tmp = ret[0];
        ret[0] = ret[1];
        ret[1] = tmp;
    }
    return ret;
}
int main()
{
    int arr[] = { 3,2,4 };
    int* ret = twoSum(arr, 3, 6, NULL);
}